import { BasicPageParams, BasicFetchResult } from '@/api/model/baseModel';

/**
 * 系统日志搜索
 */
export type LogsPageParams = BasicPageParams & {
  pages?: string;
  path?: string;
  ip?: string;
  admin_id?: number;
  data?: string;
};

/**
 * 系统日志列表数据
 */
export interface LogsListItem {
  id: number | string;
  admin_id: number;
  username: string;
  true_name: string;
  path: string;
  page: string;
  method: string;
  ip: string;
  ip_data: string;
  type: string;
  create_time: number | string;
}

// 系统日志数据列表
export type LogsListGetResultModel = BasicFetchResult<LogsListItem>;

/**
 * 系统登录日志搜索
 */
export type LoginLogsListParams = {
  uid?: number;
  data?: string;
  ip?: string;
  status?: number;
};

/**
 * 系统登录日志列表数据
 */
export interface LoginLogsListItem {
  id: number;
  uid: string;
  login_time: string;
  ip: string;
  ip_data: string;
  status: number;
}

// 系统登录日志搜索
export type LoginLogsPageParams = BasicPageParams & LoginLogsListParams;
// 系统登录日志数据列表
export type LoginLogsListGetResultModel = BasicFetchResult<LoginLogsListItem>;
